package com.lqq.designPattern.bulider_pattern.singleton.demo1;

public class Client {
    public static void main(String[] args) {
        //1.创建Single类的对象
        //Singleton singleton = new Singleton();不能这么创建，因为构造器已经私有
        Singleton instance1 = Singleton.getInstance();
        //2.再次创建Single类的对象
        Singleton instance2 = Singleton.getInstance();
        //判断是否为同一个对象
        System.out.println("是否为同一个对象" + (instance1 == instance2));
    }
}
